import request from '@/utils/request'
// 获取题库信息
export const getQuestionlist = (params) => {
  return request.get('/exam/question', { params })
}
// 获取学科列表
export const getSubjectList = (params) => {
  return request.get('/subject/subject', { params })
}
// 获取目录列表
export const getCatalogList = (params) => {
  return request.get('/subject/directory', { params })
}
// 获取标签名称列表
export const getTagList = (params) => {
  return request.get('/subject/tag', { params })
}
// 审核是否通过
export const checkPass = (data) => {
  return request.post('/exam/question/check', data)
}
// 上架
export const UpQuestion = (data) => {
  return request.post('/exam/question/show', data)
}
// 删除功能
export const delQuestion = (id) => {
  return request.delete(`/exam/question/${id}`)
}
// 添加题库信息
export const addQuestion = (data) => {
  return request.post('/exam/question', data)
}
// 获取题库详细信息
export const getQuestionDetail = (id) => {
  return request.get(`/exam/question/${id}`)
}
// 编辑题库信息
export const editQuestion = (data) => {
  return request.put(`/exam/question/${data.id}`, data)
}
